<template>
  <div class="about">
    <h1>This is an about page</h1>
    <button @click="btnfun">HOME</button>
  </div>
</template>

<script setup>
// import { useRouter } from 'vue-router'
// const router = useRouter()

// import router from '../router/index'
import $axios from '../tools/axios'
const btnfun = () => {
  // console.log($axios.defaults.headers.common.Authorization)
  // $axios.defaults.headers.common.Authorization = 'aaaaaaa'
  // console.log($axios.defaults.headers.common.Authorization)
  console.log($axios.defaults.headers.common.Authorization)
  const token =
    'eyJhbGciOiJIUzI1NiIsInppcCI6IkRFRiJ9.eNqqVkpPzUtJLVKyUno-ZbuSjlJOfnpmCpBXUpIM5BWB2YkpuZl5QF5qRYGSlaGZhaWhsbGBhVktAAAA__8.CQ3BlQI23g8Ll2dnN7HKTHUVjxVaZNb48PFcdbC0y4o'
  $axios.defaults.headers.common.Authorization = token
  $axios.defaults.headers.common.roleid = 'abc'
  $axios.defaults.headers.common.pid = 'efg'
  console.log($axios.defaults.headers.common.Authorization)
  $axios
    .get('/t/a')
    .then((res) => {
      console.log(res)
    })
    .catch((err) => {
      console.log(err)
    })
}

// import { useAboutStore } from '../stores/about'

// const aboutStore = useAboutStore()

// router.push('/')
</script>

<style>
@media (min-width: 1024px) {
  .about {
    min-height: 100vh;
    display: flex;
    align-items: center;
  }
}
</style>
